<extend name="Layout/ins_page" />
<block name="content">
	{:W('PageHeader/simple',array('name'=>'编辑工作日志','search'=>'N'))}
	<form method='post' id="form_data" name="form_data" enctype="multipart/form-data"   class="well form-horizontal">
		<input type="hidden" id="id" name="id" value="{$vo.id}">
		<input type="hidden" id="ajax" name="ajax" value="0">
		<input type="hidden" id="add_file" name="add_file" value="{$vo.add_file}">
		<input type="hidden" id="opmode" name="opmode" value="edit">
		<div class="form-group col-sm-12">
			<label class="col-sm-2 control-label" for="start_date">日期：</label>
			<div class="col-sm-10">
				<div class="input-daterange input-group" >
					<input id="start_date" value="{$vo.start_date}" type="text" class="input-sm form-control text-center" name="start_date" readonly="readonly"/>
					<span class="input-group-addon">-</span>
					<input id="end_date" value="{$vo.end_date}"  type="text" class="input-sm form-control text-center" name="end_date" readonly="readonly"/>
				</div>
			</div>
		</div>
		<div class="form-group">
			<label class="col-sm-2 control-label" for="name">附件：</label>
			<div class="col-sm-10">
				{:W('FileUpload/edit',array('add_file'=>$vo['add_file']))}
			</div>
		</div>
		<div class="form-group">
			<div class="col-sm-6">
				<p class="text-center">
					工作内容
				</p>
				<textarea class="simple" id="content" name="content" style="width:100%;height:300px;" check="require" msg="请输入本周工作内容">{$vo.content}</textarea>
			</div>
			<div class="col-sm-6">
				<p class="text-center">
					工作计划
				</p>
				<textarea class="simple" id="plan" name="plan" style="width:100%;height:300px;" check="require" msg="请输入下周工作计划">{$vo.plan}</textarea>
			</div>
		</div>
		<div class="action">
			<input class="btn btn-sm btn-primary" type="button" value="保存" onclick="save();">
			<input class="btn btn-sm btn-default" type="button" value="取消" onclick="go_return_url();">
		</div>
	</form>
</block>
<block name="js">
	<script>
		function save() {
			sendForm("form_data", "{:U('save')}");
		}
	</script>

</block>